TxnSet

class TxnSet @JvmOverloads constructor(txnList: Collection<AbstractTxn>? = null) : Iterable<AbstractTxn>

An unsynchronized (unlike Vector) storage for AbstractTxn objects.

Constructors

Link copied to clipboard
constructor(txnList: Collection<AbstractTxn>? = null)

Properties

Link copied to clipboard
Link copied to clipboard
val size: Int

Functions

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Returns true if the given transaction is in this TxnSet. Note: this is only available as of build 273.

Link copied to clipboard
Link copied to clipboard

Returns an iterator that will return transactions from the list in the same order as they are sorted

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun indexOf(txn: AbstractTxn?): Int
Link copied to clipboard
Link copied to clipboard
open operator override fun iterator(): Iterator<AbstractTxn>

Returns an iterator over the transaction in this set, in reverse order. Note that java.util.Iterator.remove is not supported by this iterator.

Link copied to clipboard
fun recalcBalances(startBalance: Long, negateBalances: Boolean)
fun recalcBalances(startBalance: Long, negateBalances: Boolean, reverseOrder: Boolean)
Link copied to clipboard

Remove all objects that are in the given collection

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Returns an iterator that will return transactions from the list in the reverse order as they are sorted

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun sortByField(sortField: Int)

Sort the transactions in this TxnSet by the given field (defined as ints in AccountUtil)

Link copied to clipboard

Sort the transactions in this TxnSet using the given comparator. A set of transaction comparators are available in the TxnUtil class.

Link copied to clipboard
fun swap(index1: Int, index2: Int)
Link copied to clipboard

Return a copy of an array with all of the transactions in it. Note: this is only available as of build 273.